/* 
 * File:   driverRN41.h
 * Author: bram
 *
 * Created on December 1, 2013, 2:44 AM
 */

#ifndef DRIVERRN41_H
#define	DRIVERRN41_H

#ifdef	__cplusplus
extern "C" {
#endif

struct PriorityPacket_t
{
	BYTE packetId;
	BOOL confirmed;
	BOOL sent;
	BOOL claimed;
	SHORT length;
    SHORT remoteConfirm;
	BYTE packet[1024];
	TickType_t sentAt;
};

void TaskRN41(void * parameters);
unsigned char rnGetParam(int pos);


BOOL rnClaimTx(int timeout);
BYTE * rnGetTxBuffer();
BOOL rnTransmitAndConfirmBlock(BYTE * buffer, unsigned short length);
void rnReleaseTx();

#ifdef	__cplusplus
}
#endif

#endif	/* DRIVERRN41_H */

